<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%><%@ taglib
	uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>

<head>
<title>课程详情</title>
<!-- Bootstrap -->
<link
	href="${pageContext.request.contextPath }/bootstrap/css/bootstrap.min.css"
	rel="stylesheet" media="screen">
<link
	href="${pageContext.request.contextPath }/bootstrap/css/bootstrap-responsive.min.css"
	rel="stylesheet" media="screen">
<link
	href="${pageContext.request.contextPath }/vendors/easypiechart/jquery.easy-pie-chart.css"
	rel="stylesheet" media="screen">
<link href="${pageContext.request.contextPath }/assets/styles.css"
	rel="stylesheet" media="screen">
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">

<script
	src="${pageContext.request.contextPath }/vendors/modernizr-2.6.2-respond-1.1.0.min.js"></script>
</head>

<body>
	<div class="navbar navbar-fixed-top">
		<div class="navbar-inner">
			<div class="container-fluid">
				<a class="btn btn-navbar" data-toggle="collapse"
					data-target=".nav-collapse"> <span class="icon-bar"></span> <span
					class="icon-bar"></span> <span class="icon-bar"></span>
				</a> <a class="brand" href="#">选课系统</a>
				<div class="nav-collapse collapse">
					<ul class="nav pull-right">
						<li class="dropdown"><a href="#" role="button"
							class="dropdown-toggle" data-toggle="dropdown"> <i
								class="icon-user"> </i>${sessionScope.teacher.academy.name }
								${sessionScope.teacher.name }<i class="caret"></i>

						</a>
							<ul class="dropdown-menu">
								<li><a tabindex="-1" href="user_logout.action?id=1">退出</a></li>
							</ul></li>
					</ul>
					<ul class="nav">
						<li class="active"><a>${requestScope.course.name }</a></li>
						<li class="dropdown">
						    <a  class="dropdown-toggle" href="#" data-toggle="dropdown">查看全部课程</a>
							<ul class="dropdown-menu" id="menu1">
								<li><a href="teacher_checkAll.action?id=1">查看全部课程</a>
								</li>
						    </ul>
						</li>
						<li class="dropdown"><a  class="dropdown-toggle" href="#" data-toggle="dropdown">新增课程</a>
							<ul class="dropdown-menu" id="menu1">
								<li><a href="teacher_addCourse.action?id=1">新增课程</a>
								</li>
						    </ul>
						</li>
					</ul>
				</div>
				<!--/.nav-collapse -->
			</div>
		</div>
	</div>
	<div class="container-fluid">
		<div class="row-fluid">
			<div class="span2" id="sidebar">
				<ul class="nav nav-list bs-docs-sidenav nav-collapse collapse">
					<li class="active"><a href="teacher_checkAll.action?id=1">查看全部课程</a></li>
					<c:forEach var="course" items="${sessionScope.teacher.courses }">
						<li><a href="teacher_checkCourse.action?cid=${course.id }"><i
								class="icon-chevron-right"></i>${course.name }</a></li>
					</c:forEach>
					<li class="active"><a href="teacher_addCourse.action?id=1"><i
							class="icon-chevron-right"></i>新增课程</a></li>
				</ul>
			</div>
			<!--/span-->
			<div class="span10" id="content">				
			    <c:if test="${!empty message }">
					<div class="row-fluid">
						<div class="alert alert-success">
							<button type="button" class="close" data-dismiss="alert">&times;</button>
							<h4>提示</h4>
							${message }
						</div>
					</div>
				</c:if>
				<div class="row-fluid">
					<div class="span6">
						<!-- block -->
						<div class="block">
							<div class="navbar navbar-inner block-header">
								<div class="muted pull-left">学生列表(${requestScope.course.selected }/${requestScope.course.sum })</div>
								<div class="pull-right">
									<span class="badge badge-info">${fn:length(requestScope.course.scs) }</span>

								</div>
							</div>
							<div class="block-content collapse in">
								<table class="table table-striped">
									<thead>
										<tr>
											<th>学号</th>
											<th>姓名</th>
											<th>学院</th>
											<th>班级</th>
											<th>email</th>
											<th>退选</th>
										</tr>
									</thead>
									<tbody>
									    <c:forEach var="sc" items="${requestScope.course.scs }">
										    <tr>
											    <td>${sc.student.id }</td>
											    <td>${sc.student.name }</td>
											    <td>${sc.student.academy.name }</td>
											    <td>${sc.student.classes.name }</td>
											    <td>${sc.student.email }</td>
											    <td><a class="btn btn-primary" href="teacher_dropCourse.action?sid=${sc.id }&cid=${sc.course.id }">退选</a></td>
										    </tr>
										</c:forEach>
									</tbody>
								</table>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>
	</div>

	<!--/.fluid-container-->
	<script
		src="${pageContext.request.contextPath }/vendors/jquery-1.9.1.min.js"></script>
	<script
		src="${pageContext.request.contextPath }/bootstrap/js/bootstrap.min.js"></script>
	<script
		src="${pageContext.request.contextPath }/vendors/easypiechart/jquery.easy-pie-chart.js"></script>
	<script src="${pageContext.request.contextPath }/assets/scripts.js"></script>
	<script>
		$(function() {
			// Easy pie charts
			$('.chart').easyPieChart({
				animate : 1000
			});
		});
	</script>
</body>

</html>